package org.example.lethear.dto.user;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.time.LocalDateTime;
import java.util.Set;

/**
 * 用户信息DTO
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
public class UserDTO {
    
    private Long id;
    private String username;
    private String email;
    private String nickname;
    private String avatar;
    private Integer status; // 用户状态：0-禁用，1-正常
    private Boolean enabled;
    private Boolean emailVerified;
    private Set<String> roles;
    private LocalDateTime lastLoginTime;
    private LocalDateTime createdAt;
    private LocalDateTime updatedAt;
    
    /**
     * 用户资料信息
     */
    private UserProfileDTO profile;
    
    /**
     * 统计信息
     */
    private UserStats stats;
    
    /**
     * 用户统计信息内部类
     */
    @Data
    @NoArgsConstructor
    @AllArgsConstructor
    @Builder
    public static class UserStats {
        private Long postCount;
        private Long commentCount;
        private Long followingCount;
        private Long followerCount;
        private Long likeCount;
        private Long whisperCount;
    }
} 